<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
            border: 0;
            text-decoration: none;
            text-transform: uppercase;
            letter-spacing: .3em;
        }

        body {
            width: 100vw;
            height: 100vh;
            display: flex;
            justify-content: center;
            align-items: center;
            background-color: #2C3E50;
        }

        main {
            width: 300px;
            height: 150px;
            background-color: #E74C3C;
            display: flex;
            justify-content: center;
            align-items: center;
            position: relative;
            transform-style: preserve-3d;
            transform: perspective(600px) rotateX(40deg) rotateY(3deg) rotateZ(13deg);

        }

        /* main:hover {
            transform: perspective(600px) rotateX(350deg) rotateY(150deg) rotateZ(180deg);
        } */

        .btn {
            color: #fff;
            font-size: 2rem;
            width: 100%;
            height: 100%;
            display: flex;
            justify-content: center;
            align-items: center;

        }

        .btn::before {
            content: "开";
            position: absolute;
            top: 0;
            left: 0;
            width: 50%;
            height: 100%;
            display: flex;
            align-items: center;
            justify-content: flex-end;
            background-color: #D35400;
            transition: 2s;
            transform-origin: left center;

        }

        .btn::after {
            content: "学";
            position: absolute;
            top: 0;
            right: 0;
            width: 50%;
            height: 100%;
            display: flex;
            align-items: center;
            justify-content: flex-start;
            background-color: #D35400;
            transition: 2s;
            transform-origin: right center;
        }

        .btn:hover::before {
            transform: perspective(900px) rotateY(-180deg);
        }

        .btn:hover::after {
            transform: perspective(900px) rotateY(180deg);
        }
    </style>
</head>

<body>
    <main>
        <a href="#" class="btn"> 贺卡 </a>
    </main>
</body>

</html>